package com.ruoyi.system.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 小程序用户登录日志表
 * @TableName mini_login_log
 */
@TableName(value ="mini_login_log")
@Data
@AllArgsConstructor
@NoArgsConstructor
public class MiniLoginLog implements Serializable {
    /**
     * id
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 用户id
     */
    private Long userId;

    /**
     * 小程序openid
     */
    private String openid;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    public MiniLoginLog(Long userId, String openid) {
        this.userId = userId;
        this.openid = openid;
    }

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}